package cn.dakaqi.entities;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;

import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;

/**
 * Created by chunyang on 2016/4/13.
 * 活动地址
 */
@Entity
@Table(name = "U_ACTIVITY_ADDRESS")
public class ActivityAddress extends IdEntity
{

    private static final long serialVersionUID = -9079257133257118140L;
    private String name;    //地址名称
    private String province;
    private String city;
    private String district;
    private String address;//地址
    private String memberCode;//创建者
    private Double lng = 0.0;
    private Double lat = 0.0;
    private int delStatus;//
    private Date createTime;

    public Double getLng()
    {
        return lng;
    }

    public void setLng(Double lng)
    {
        this.lng = lng;
    }

    public Double getLat()
    {
        return lat;
    }

    public void setLat(Double lat)
    {
        this.lat = lat;
    }

    public String getProvince()
    {
        return province;
    }

    public void setProvince(String province)
    {
        this.province = province;
    }

    public String getCity()
    {
        return city;
    }

    public void setCity(String city)
    {
        this.city = city;
    }

    public String getDistrict()
    {
        return district;
    }

    public void setDistrict(String district)
    {
        this.district = district;
    }

    public String getName()
    {
        return name;
    }

    public void setName(String name)
    {
        this.name = name;
    }

    public String getAddress()
    {
        return address;
    }

    public void setAddress(String address)
    {
        this.address = address;
    }

    @JsonIgnore
    public String getMemberCode()
    {
        return memberCode;
    }

    public void setMemberCode(String memberCode)
    {
        this.memberCode = memberCode;
    }
    @JsonIgnore
    public int getDelStatus()
    {
        return delStatus;
    }

    public void setDelStatus(int delStatus)
    {
        this.delStatus = delStatus;
    }

    // 设定JSON序列化时的日期格式
    @JsonIgnore
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getCreateTime()
    {
        return createTime;
    }

    public void setCreateTime(Date createTime)
    {
        this.createTime = createTime;
    }
}
